package com.team.sns.entities;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

@Entity
public class MessageBoard implements Serializable {

	private static final long serialVersionUID = 3447137195568458869L;

	private String id;
	private String content;
	private String messageUserId;
	private Date createDate = new Date();

	@Id @Column(nullable=false,length=36)
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@Column(length = 1000, nullable = false)
	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	@Column(length = 20, nullable = false)
	public String getMessageUserId() {
		return messageUserId;
	}

	public void setMessageUserId(String messageUserId) {
		this.messageUserId = messageUserId;
	}

	@Column(length = 22, nullable = false)
	@Temporal(TemporalType.TIMESTAMP)
	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

}
